package com.chan.domain;

import com.chan.common.annotation.Excel;
import com.chan.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;


/**
 * 文档库对象 cd_document
 *
 * @author chan
 * @date 2024-04-25
 */
public class CdDocument extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /**  */
    private Long id;

    /** 关联ID */
    @Excel(name = "关联ID")
    private Long relateId;

    /** 关联类型（1 项目集  2 项目  3 任务） */
    @Excel(name = "关联类型", readConverterExp = "1=,项=目集,2=,项=目,3=,任=务")
    private Long relateType;

    /** 分组文件夹父ID */
    @Excel(name = "分组文件夹父ID")
    private Long parentId;

    /** 文档分组文件夹 */
    @Excel(name = "文件或文件夹名称")
    private String title;

    /** 文档路径 */
    @Excel(name = "文档路径")
    private String url;

    /** 项目描述 */
    @Excel(name = "项目描述")
    private String desc;

    /** 排序 */
    @Excel(name = "排序")
    private Long rank;
    /** 类型（1 文件夹 2 文件  3 图片） */
    private Integer type;

    public void setId(Long id)
    {
        this.id = id;
    }

    public Long getId()
    {
        return id;
    }
    public void setRelateId(Long relateId)
    {
        this.relateId = relateId;
    }

    public Long getRelateId()
    {
        return relateId;
    }
    public void setRelateType(Long relateType)
    {
        this.relateType = relateType;
    }

    public Long getRelateType()
    {
        return relateType;
    }
    public void setParentId(Long parentId)
    {
        this.parentId = parentId;
    }

    public Long getParentId()
    {
        return parentId;
    }
    public void setTitle(String title)
    {
        this.title = title;
    }

    public String getTitle()
    {
        return title;
    }
    public void setUrl(String url)
    {
        this.url = url;
    }

    public String getUrl()
    {
        return url;
    }
    public void setDesc(String desc)
    {
        this.desc = desc;
    }

    public String getDesc()
    {
        return desc;
    }
    public void setRank(Long rank)
    {
        this.rank = rank;
    }

    public Long getRank()
    {
        return rank;
    }

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("relateId", getRelateId())
            .append("relateType", getRelateType())
            .append("parentId", getParentId())
            .append("title", getTitle())
            .append("url", getUrl())
            .append("desc", getDesc())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .append("rank", getRank())
            .append("type", getType())
            .toString();
    }
}
